function base_search(arr,target){
    for (let i = 0; i < arr.length; i++) {
        if(arr[i]===target){
            return i
        }
    }
    return -1;

}

let array = [2, 3, 5, 12, 22, 34, 35, 67]
console.log(base_search(array, 12));